<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>ECharts 实例</title>
    <!-- 引⼊ echarts.js -->
    <script src="https://cdn.staticfile.org/echarts/4.3.0/echarts.min.js"></script>
</head>
<body>
<!-- 为ECharts准备⼀个具备⼤⼩（宽⾼）的Dom -->
    <div id="main" style="width: 600px;height:400px;"></div>
    <script type="text/javascript">
// 基于准备好的dom，初始化echarts实例
        var myChart = echarts.init(document.getElementById('main'));
// 指定图表的配置项和数据
        var option = {series: {type: 'sunburst', data: [
            {name: '流失用户', value: 183472},
            {name: '回流用户', value: 6546},
            {name: '连续活跃用户', value: 524},
            {name: '新用户', value: 91},
            {name: '活跃用户', value: 0}]
            }
        };
// 使⽤刚指定的配置项和数据显示图表。
        myChart.setOption(option);
    </script>
</body>
</html